<div class="blazorise-codeblock">
<div class="html"><pre>
<span class="htmlTagDelimiter">&lt;</span><span class="htmlElementName">Scheduler</span> <span class="htmlAttributeName">TItem</span><span class="htmlOperator">=</span><span class="quot">&quot;</span><span class="htmlAttributeValue">Appointment</span><span class="quot">&quot;</span> <span class="htmlAttributeName">Data</span><span class="htmlOperator">=</span><span class="quot">&quot;</span><span class="sharpVariable"><span class="atSign">&#64;</span>Appointments</span><span class="quot">&quot;</span> <span class="htmlAttributeName">SelectedView</span><span class="htmlOperator">=</span><span class="quot">&quot;</span><span class="enum">SchedulerView</span><span class="enumValue">.Week</span><span class="quot">&quot;</span><span class="htmlTagDelimiter">&gt;</span>
    <span class="htmlTagDelimiter">&lt;</span><span class="htmlElementName">SchedulerToolbar</span> <span class="htmlTagDelimiter">/&gt;</span>
    <span class="htmlTagDelimiter">&lt;</span><span class="htmlElementName">SchedulerViews</span><span class="htmlTagDelimiter">&gt;</span>
        <span class="htmlTagDelimiter">&lt;</span><span class="htmlElementName">SchedulerWeekView</span> <span class="htmlAttributeName">ViewHeight</span><span class="htmlOperator">=</span><span class="quot">&quot;</span><span class="htmlAttributeValue">500</span><span class="quot">&quot;</span> <span class="htmlTagDelimiter">/&gt;</span>
    <span class="htmlTagDelimiter">&lt;/</span><span class="htmlElementName">SchedulerViews</span><span class="htmlTagDelimiter">&gt;</span>
<span class="htmlTagDelimiter">&lt;/</span><span class="htmlElementName">Scheduler</span><span class="htmlTagDelimiter">&gt;</span>
</pre></div>
<div class="csharp"><pre>
<span class="atSign">&#64;</span>code {
    <span class="keyword">private</span> <span class="keyword">static</span> DateTime today10AM = DateTime.Today.AddHours( <span class="number">10</span> );

    <span class="keyword">public</span> <span class="keyword">class</span> Appointment
    {
        <span class="keyword">public</span> Appointment()
        {
        }

        <span class="keyword">public</span> Appointment( <span class="keyword">string</span> title, <span class="keyword">string</span> description, DateTime start, DateTime end, <span class="keyword">bool</span> allDay = <span class="keyword">false</span> )
        {
            Id = Guid.NewGuid().ToString();
            Title = title;
            Description = description;
            Start = start;
            End = end;
            AllDay = allDay;
        }

        <span class="keyword">public</span> <span class="keyword">string</span> Id { <span class="keyword">get</span>; <span class="keyword">set</span>; }

        <span class="keyword">public</span> <span class="keyword">string</span> Title { <span class="keyword">get</span>; <span class="keyword">set</span>; }

        <span class="keyword">public</span> <span class="keyword">string</span> Description { <span class="keyword">get</span>; <span class="keyword">set</span>; }

        <span class="keyword">public</span> DateTime Start { <span class="keyword">get</span>; <span class="keyword">set</span>; }

        <span class="keyword">public</span> DateTime End { <span class="keyword">get</span>; <span class="keyword">set</span>; }

        <span class="keyword">public</span> <span class="keyword">bool</span> AllDay { <span class="keyword">get</span>; <span class="keyword">set</span>; }

        <span class="keyword">public</span> <span class="keyword">string</span> RecurrenceRule { <span class="keyword">get</span>; <span class="keyword">set</span>; }
    }

    List&lt;Appointment&gt; Appointments = <span class="keyword">new</span> List&lt;Appointment&gt;
    {
        <span class="keyword">new</span> Appointment( <span class="string">&quot;Meeting with the CEO&quot;</span>, <span class="string">&quot;Regarding the new margeting strategy&quot;</span>, today10AM, today10AM.AddHours(<span class="number">1</span>) ),
        <span class="keyword">new</span> Appointment( <span class="string">&quot;Some other meeting&quot;</span>, <span class="string">&quot;Regarding the new margeting strategy&quot;</span>, today10AM, today10AM.AddHours(<span class="number">1</span>) ),
        <span class="keyword">new</span> Appointment( <span class="string">&quot;Lunch with the team&quot;</span>, <span class="string">&quot;Discussing the new project&quot;</span>, today10AM.AddDays(-<span class="number">10</span>).AddHours(<span class="number">2</span>), today10AM.AddDays(-<span class="number">10</span>).AddHours(<span class="number">3</span>))
        {
            RecurrenceRule = <span class="string">&quot;FREQ=WEEKLY;BYDAY=MO,TU,WE,TH,FR;INTERVAL=2;COUNT=3&quot;</span>
        },
    };
}
</pre></div>
</div>
